Skip to content

Add Emoji support for Image + Fix issues in component generation #399

Merged
brionmario merged 11 commits intoasgardeo:mainfrom
brionmario:refactor-thunder-flows
Mar 15, 2026
Merged

Add Emoji support for Image + Fix issues in component generation #399
brionmario merged 11 commits intoasgardeo:mainfrom
brionmario:refactor-thunder-flows

Conversation

@brionmario
Copy link
Member

@brionmario brionmario commented Mar 14, 2026

Purpose

This pull request introduces several new utility functions and refactors existing code to improve support for flow template literals and emoji URIs in the JavaScript SDK. The main changes include the addition of new helpers for detecting and extracting emoji URIs, enhanced parsing and resolution of flow template literals (such as {{ t(key) }} and {{ meta(path) }}), and updates to the React ImageComponent to render emoji URIs as scalable emoji icons. The exports and type names have also been updated for clarity and consistency.

The most important changes are:

Flow Template Literal Support

  • Added new utilities for parsing and handling flow template literals, including parseFlowTemplateLiteral, isMetaFlowTemplateLiteral, isTranslationFlowTemplateLiteral, and containsMetaFlowTemplateLiteral, enabling robust detection and extraction of translation and metadata expressions within strings. [1] [2] [3] [4]
  • Refactored the variable resolution logic: replaced resolveVars with resolveFlowTemplateLiterals, updated its implementation to use the new parsing utilities, and renamed related types for clarity. [1] [2] [3] [4] [5]

Emoji URI Handling

  • Introduced isEmojiUri and extractEmojiFromUri helpers to identify and extract emoji characters from URIs with the emoji: scheme. [1] [2] [3]
Screenshot 2026-03-14 at 07 41 06

React Component Enhancement

  • Updated the ImageComponent in React to support rendering emoji URIs as scalable emoji icons using the new emoji utilities, improving visual consistency and accessibility for emoji-based images. [1] [2]

Codebase Organization and Exports

  • Updated exports in index.ts to expose the new utilities and renamed types, ensuring that consumers of the SDK have access to the latest helpers. [1] [2]

These changes collectively improve the SDK's flexibility in handling dynamic content and enhance support for both internationalization and emoji-based UI elements.

Related Issues

Related PRs

  • N/A

Checklist

  • Followed the CONTRIBUTING guidelines.
  • Manual test round performed and verified.
  • Documentation provided. (Add links if there are any)
  • Unit tests provided. (Add links if there are any)

Security checks

@brionmario brionmario force-pushed the refactor-thunder-flows branch from 29deb0d to 455296d Compare March 14, 2026 19:29
@brionmario brionmario changed the title Refactor thunder flows Add Emoji support for Image + Fix issues in component generation Mar 14, 2026
@asgardeo-github-bot
Copy link

🦋 Changeset detected

The changes in this PR will be included in the next version bump.

Not sure what this means? Click here to learn what changesets are.

@brionmario brionmario merged commit ecfbdd6 into asgardeo:main Mar 15, 2026
6 of 8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants